<template>
  <div id="app">
    <router-view/>
  </div>
</template>

<script>
import { setToken } from '@/utils/auth'
export default {
  name: 'App',
  watch: {
    '$route'(to, from) {
      console.log(to, from);
      const { jwt } = to.query
      if (jwt) {
        setToken(jwt)
      }
    }
  },
}
</script>

<style>
#app {
  width:100%;
  height:100%;
  font-family: 'Avenir', Helvetica, Arial, sans-serif;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  color:#333;
}
</style>
